package com.example.music.service.impl;

import com.example.music.domain.Administrators;
import com.example.music.mapper.AdministratorsMapper;
import com.example.music.service.IAdministratorsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class AdministratorsServiceImpl implements IAdministratorsService {
    @Autowired
    private  AdministratorsMapper administratorsMapper;

    public List<Administrators> getAdministrators(){
        return administratorsMapper.getAdministrators();
    }
    public List<Administrators> selectAdministratorsByName(String name){
        return administratorsMapper.selectAdministratorsByName(name);
    }
    public Administrators selectAdministratorsById(Long id){
        return administratorsMapper.selectAdministratorsById(id);
    }
    public int insertAdministrators(Administrators administrators){
        return administratorsMapper.insertAdministrators(administrators);
    }
    public int updateAdministrators(Administrators administrators){
        return administratorsMapper.updateAdministrators(administrators);
    }
    public int deleteAdministratorsById(Long id){
        return administratorsMapper.deleteAdministratorsById(id);
    }
}
